Skip to content

runtime: keep natural slice allocation on a direct fast path - #3063

Open
cpunion wants to merge 2 commits into
xgo-dev:mainfrom
cpunion:fix/3045-inline-natural-alloc-20261112
Open

cpunion wants to merge 2 commits into
xgo-dev:mainfrom
cpunion:fix/3045-inline-natural-alloc-20261112

Conversation

@cpunion

@cpunion cpunion commented Nov 11, 2026 •

Copy link
Copy Markdown
Collaborator

Keep the MakeSlice entry point on a direct naturally aligned path, sharing boundary checks with MakeSliceAligned:

Before: MakeSlice -> allocAligned -> GC_malloc[_atomic]
After:  MakeSlice -> GC_malloc[_atomic]

macOS arm64, LLVM 22, O3/full LTO; median timings:

Benchmark main PR
GC struct interpreter 94.53 ns/iteration 90.97 ns/iteration
4 B allocation 7.671 ns/op 7.603 ns/op
64 B allocation 16.035 ns/op 16.060 ns/op

GC workload paired time improves 4.2% (95% CI: 3.3–4.6%); microbenchmarks are unchanged within noise. Protocol and raw block means: 12 randomized paired blocks, 101 samples/process, A/A calibrated.

Validation: full native runtime suite, O0 boundary checks, WASI and Emscripten32/64 O3/full-LTO tests; zeroing, collector kinds, pointer survival and over-alignment remain covered.

Fixes #3045.

@cpunion

cpunion commented Nov 11, 2026

Copy link
Copy Markdown
Collaborator Author

Performance validation uses frozen wasmvm source 2e5ee34d8070595e86cd7a7bec1ffc1da33a696e and benchmarks/modern/gc-struct-allocation.wasm (SHA-256 c85f7a1094a0dda5078f1f293017760d55252f5b7693f15a1ce4859c46bd49db). All timed results remain 2520546209.

Build all runners with Go 1.27.3, LLVM/lld 22.1.8, -O3 -lto=full, and LLGO_ESCAPE_CACHE=0. Run with GOMAXPROCS=1:

runner --mode api --backend interpreter --wasm gc-struct-allocation.wasm \
  --iterations 10000 --seed 17 --expected 2520546209 --samples 101 --warmups 10
# Send "run\n" on stdin after the ready handshake.

This is a separate extended-sampling cohort (101 timed calls per process), not the original issue's seven-sample protocol. Twelve blocks each contain two fresh processes for old 3d92a58, main 96331c1, and this change; shuffle all six trials with seed 2026111204. Retain every timed call, including GC pauses and outliers. The per-process metric is the arithmetic mean of all warm calls divided by 10,000.

Runner Median ns/iteration A/A paired ratio, 95% CI
Old 3d92a58 91.418 0.9928 [0.9765, 0.9991]
Main 96331c1 94.527 1.0006 [0.9942, 1.0164]
This PR 90.973 0.9966 [0.9892, 1.0099]

The A/A intervals fit the issue's ±2.5% calibration budget. Paired head/main ratio is 0.9580 [0.9536, 0.9667]; head/old is 0.9921 [0.9877, 0.9981]. These are medians of block ratios using the geometric mean of each block's two processes; percentile bootstrap uses 10,000 block resamples and seed 2026111205.

The separate fixed-count small/medium allocation benchmark is essentially flat (head/base intervals include 1); this is a validated improvement for the interpreter workload above, not evidence of a universal allocator speedup. Earlier short-sample exploratory cohorts had excessive A/A noise and are not pooled into these results.

Raw per-process means for the complete calibrated cohort (ns/iteration):

block,old_A,old_B,main_A,main_B,head_A,head_B
1,91.673224,90.549713,92.125447,94.277180,92.074546,91.511842
2,91.210681,90.843809,94.067651,97.256598,92.235936,90.274681
3,91.574752,91.253920,92.567078,94.497857,90.554126,90.364973
4,91.011143,90.467367,94.875950,93.934407,91.739848,88.279285
5,91.623646,91.871162,95.189272,96.333498,89.991100,92.113614
6,93.967244,91.296616,94.718188,94.595495,91.802105,90.990551
7,93.626566,91.114605,95.466210,94.622522,90.196192,91.528664
8,91.917440,90.058494,93.843966,93.583135,89.735446,90.181811
9,91.570132,91.730981,95.319880,95.501735,91.267821,90.842746
10,92.667373,89.727648,97.786926,94.556063,89.632751,92.407222
11,91.125095,92.677230,93.188070,94.223392,91.122116,89.954248
12,91.539191,90.763607,92.757966,92.699014,90.962130,90.983791

@fennoai fennoai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review summary

The new MakeSlice fast path does the same thing as before. makeSliceMemory runs the same overflow, maxAlloc, len < 0 and len > cap checks, with the same panic messages. With an alignment of 1, the old allocAligned path also ended at AllocZ / AllocAtomicZ. So skipping its alignment check and duplicate maxAlloc check is safe. Memory is still zeroed, slices whose elements contain pointers still get scanned memory, and over-aligned slices still use MakeSliceAligned. The tests cover the zero-length, zero-size, overflow and collector-kind cases well.

Two optional follow-ups, both outside the diff:

  • runtime/internal/runtime/wide_32bit.go:51-53: On 32-bit targets (386, arm, mips, wasm), MakeSlice64 is used for ordinary slices whose length or capacity is wider than int. It still calls MakeSlice64Aligned(..., 1, ...), which goes MakeSliceAligned → allocZTyped → allocAligned. That is the path this PR removes from MakeSlice. To match, it could check the int64 → int conversion and then call MakeSlice. No test covers MakeSlice64.
  • runtime/internal/runtime/z_slice.go:239: When cap is larger than the stack buffer or no buffer is available, MakeSliceBuffer falls back to MakeSliceAligned(len, cap, etSize, etAlign, hasPointers). Usually etAlign is at most the word size here, because the compiler sends every non-escaping make through the buffer form. So dynamic-capacity makes that don't escape still take the slower path. Calling MakeSlice when etAlign <= unsafe.Sizeof(uintptr(0)) would give them the fast path too. The same applies to MakeSlice64Buffer. Whether this matters depends on your workload.

No blocking issues.

Comment thread runtime/internal/runtime/z_slice.go Resolved
@codecov

codecov Bot commented Nov 11, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@github-actions

Copy link
Copy Markdown

LLGo baseline benchmarks

87f8a2fb4d8d | workflow run | long-term charts

String equality benchmarks
Platform Benchmark ns/op vs base
Linux BenchmarkStringEquality/bytes/equal/1024/Go 25.970 ns/op +0.13 ns/op / +0.5% (worse)
Linux BenchmarkStringEquality/bytes/equal/1024/LLGo 62.450 ns/op -0.13 ns/op / -0.2% (better)
Linux BenchmarkStringEquality/bytes/equal/128/Go 8.362 ns/op -0.023 ns/op / -0.3% (better)
Linux BenchmarkStringEquality/bytes/equal/128/LLGo 11.940 ns/op +0.06 ns/op / +0.5% (worse)
Linux BenchmarkStringEquality/bytes/equal/8/Go 5.834 ns/op -0.017 ns/op / -0.3% (better)
Linux BenchmarkStringEquality/bytes/equal/8/LLGo 3.891 ns/op -0.786 ns/op / -16.8% (better)
Linux BenchmarkStringEquality/bytes/first/1024/Go 6.633 ns/op -0.068 ns/op / -1.0% (better)
Linux BenchmarkStringEquality/bytes/first/1024/LLGo 2.332 ns/op -1.17 ns/op / -33.4% (better)
Linux BenchmarkStringEquality/bytes/first/128/Go 6.668 ns/op +0.039 ns/op / +0.6% (worse)
Linux BenchmarkStringEquality/bytes/first/128/LLGo 2.332 ns/op -1.169 ns/op / -33.4% (better)
Linux BenchmarkStringEquality/bytes/first/8/Go 5.844 ns/op +0.019 ns/op / +0.3% (worse)
Linux BenchmarkStringEquality/bytes/first/8/LLGo 2.379 ns/op -1.163 ns/op / -32.8% (better)
Linux BenchmarkStringEquality/bytes/last/1024/Go 25.140 ns/op 0 ns/op / +0.0%
Linux BenchmarkStringEquality/bytes/last/1024/LLGo 62.540 ns/op -0.11 ns/op / -0.2% (better)
Linux BenchmarkStringEquality/bytes/last/128/Go 8.186 ns/op +0.031 ns/op / +0.4% (worse)
Linux BenchmarkStringEquality/bytes/last/128/LLGo 11.990 ns/op +0.28 ns/op / +2.4% (worse)
Linux BenchmarkStringEquality/bytes/last/8/Go 5.826 ns/op -7.074 ns/op / -54.8% (better)
Linux BenchmarkStringEquality/bytes/last/8/LLGo 3.108 ns/op -1.599 ns/op / -34.0% (better)
Linux BenchmarkStringEquality/strings/equal/1024/Go 23.260 ns/op +0.1 ns/op / +0.4% (worse)
Linux BenchmarkStringEquality/strings/equal/1024/LLGo 54.610 ns/op +0.04 ns/op / +0.1% (worse)
Linux BenchmarkStringEquality/strings/equal/128/Go 8.182 ns/op -11.53 ns/op / -58.5% (better)
Linux BenchmarkStringEquality/strings/equal/128/LLGo 11.160 ns/op -0.03 ns/op / -0.3% (better)
Linux BenchmarkStringEquality/strings/equal/8/Go 5.829 ns/op -0.024 ns/op / -0.4% (better)
Linux BenchmarkStringEquality/strings/equal/8/LLGo 4.270 ns/op -3.84 ns/op / -47.3% (better)
Linux BenchmarkStringEquality/strings/first/1024/Go 6.626 ns/op +0.012 ns/op / +0.2% (worse)
Linux BenchmarkStringEquality/strings/first/1024/LLGo 2.722 ns/op -0.003 ns/op / -0.1% (better)
Linux BenchmarkStringEquality/strings/first/128/Go 6.602 ns/op -0.018 ns/op / -0.3% (better)
Linux BenchmarkStringEquality/strings/first/128/LLGo 2.722 ns/op -0.001 ns/op / -0.03672% (better)
Linux BenchmarkStringEquality/strings/first/8/Go 5.822 ns/op +0.002 ns/op / +0.03436% (worse)
Linux BenchmarkStringEquality/strings/first/8/LLGo 2.722 ns/op -0.004 ns/op / -0.1% (better)
Linux BenchmarkStringEquality/strings/last/1024/Go 22.720 ns/op +0.05 ns/op / +0.2% (worse)
Linux BenchmarkStringEquality/strings/last/1024/LLGo 54.560 ns/op -0.04 ns/op / -0.1% (better)
Linux BenchmarkStringEquality/strings/last/128/Go 8.157 ns/op -0.016 ns/op / -0.2% (better)
Linux BenchmarkStringEquality/strings/last/128/LLGo 11.130 ns/op +0.05 ns/op / +0.5% (worse)
Linux BenchmarkStringEquality/strings/last/8/Go 5.827 ns/op -0.136 ns/op / -2.3% (better)
Linux BenchmarkStringEquality/strings/last/8/LLGo 3.495 ns/op -0.008 ns/op / -0.2% (better)
macOS BenchmarkStringEquality/bytes/equal/1024/Go 28.460 ns/op +1.38 ns/op / +5.1% (worse)
macOS BenchmarkStringEquality/bytes/equal/1024/LLGo 25.520 ns/op +0.9 ns/op / +3.7% (worse)
macOS BenchmarkStringEquality/bytes/equal/128/Go 6.266 ns/op +0.543 ns/op / +9.5% (worse)
macOS BenchmarkStringEquality/bytes/equal/128/LLGo 5.173 ns/op +0.478 ns/op / +10.2% (worse)
macOS BenchmarkStringEquality/bytes/equal/8/Go 4.320 ns/op +0.846 ns/op / +24.4% (worse)
macOS BenchmarkStringEquality/bytes/equal/8/LLGo 2.893 ns/op +0.201 ns/op / +7.5% (worse)
macOS BenchmarkStringEquality/bytes/first/1024/Go 5.017 ns/op +0.682 ns/op / +15.7% (worse)
macOS BenchmarkStringEquality/bytes/first/1024/LLGo 1.700 ns/op -0.045 ns/op / -2.6% (better)
macOS BenchmarkStringEquality/bytes/first/128/Go 4.255 ns/op +0.289 ns/op / +7.3% (worse)
macOS BenchmarkStringEquality/bytes/first/128/LLGo 1.723 ns/op -0.059 ns/op / -3.3% (better)
macOS BenchmarkStringEquality/bytes/first/8/Go 3.647 ns/op +0.169 ns/op / +4.9% (worse)
macOS BenchmarkStringEquality/bytes/first/8/LLGo 1.745 ns/op +0.055 ns/op / +3.3% (worse)
macOS BenchmarkStringEquality/bytes/last/1024/Go 25.670 ns/op +1.05 ns/op / +4.3% (worse)
macOS BenchmarkStringEquality/bytes/last/1024/LLGo 26.080 ns/op +1.81 ns/op / +7.5% (worse)
macOS BenchmarkStringEquality/bytes/last/128/Go 5.812 ns/op -1.36 ns/op / -19.0% (better)
macOS BenchmarkStringEquality/bytes/last/128/LLGo 3.986 ns/op -0.187 ns/op / -4.5% (better)
macOS BenchmarkStringEquality/bytes/last/8/Go 4.047 ns/op +0.462 ns/op / +12.9% (worse)
macOS BenchmarkStringEquality/bytes/last/8/LLGo 3.353 ns/op +0.894 ns/op / +36.4% (worse)
macOS BenchmarkStringEquality/strings/equal/1024/Go 26.300 ns/op -0.47 ns/op / -1.8% (better)
macOS BenchmarkStringEquality/strings/equal/1024/LLGo 26.930 ns/op +2.22 ns/op / +9.0% (worse)
macOS BenchmarkStringEquality/strings/equal/128/Go 5.804 ns/op +0.123 ns/op / +2.2% (worse)
macOS BenchmarkStringEquality/strings/equal/128/LLGo 4.877 ns/op +0.217 ns/op / +4.7% (worse)
macOS BenchmarkStringEquality/strings/equal/8/Go 5.976 ns/op +2.493 ns/op / +71.6% (worse)
macOS BenchmarkStringEquality/strings/equal/8/LLGo 3.828 ns/op +0.995 ns/op / +35.1% (worse)
macOS BenchmarkStringEquality/strings/first/1024/Go 4.990 ns/op +1.121 ns/op / +29.0% (worse)
macOS BenchmarkStringEquality/strings/first/1024/LLGo 1.762 ns/op +0.008 ns/op / +0.5% (worse)
macOS BenchmarkStringEquality/strings/first/128/Go 5.014 ns/op +0.946 ns/op / +23.3% (worse)
macOS BenchmarkStringEquality/strings/first/128/LLGo 1.732 ns/op -0.087 ns/op / -4.8% (better)
macOS BenchmarkStringEquality/strings/first/8/Go 3.936 ns/op +0.454 ns/op / +13.0% (worse)
macOS BenchmarkStringEquality/strings/first/8/LLGo 1.832 ns/op -0.118 ns/op / -6.1% (better)
macOS BenchmarkStringEquality/strings/last/1024/Go 29.200 ns/op +4.77 ns/op / +19.5% (worse)
macOS BenchmarkStringEquality/strings/last/1024/LLGo 23.400 ns/op -0.6 ns/op / -2.5% (better)
macOS BenchmarkStringEquality/strings/last/128/Go 5.525 ns/op -0.485 ns/op / -8.1% (better)
macOS BenchmarkStringEquality/strings/last/128/LLGo 5.031 ns/op +0.985 ns/op / +24.3% (worse)
macOS BenchmarkStringEquality/strings/last/8/Go 6.165 ns/op +2.646 ns/op / +75.2% (worse)
macOS BenchmarkStringEquality/strings/last/8/LLGo 2.466 ns/op +0.095 ns/op / +4.0% (worse)
Windows MinGW BenchmarkStringEquality/bytes/equal/1024/Go 20.210 ns/op -0.22 ns/op / -1.1% (better)
Windows MinGW BenchmarkStringEquality/bytes/equal/1024/LLGo 42.100 ns/op +0.54 ns/op / +1.3% (worse)
Windows MinGW BenchmarkStringEquality/bytes/equal/128/Go 7.606 ns/op +0.057 ns/op / +0.8% (worse)
Windows MinGW BenchmarkStringEquality/bytes/equal/128/LLGo 10.870 ns/op -0.11 ns/op / -1.0% (better)
Windows MinGW BenchmarkStringEquality/bytes/equal/8/Go 5.885 ns/op -0.234 ns/op / -3.8% (better)
Windows MinGW BenchmarkStringEquality/bytes/equal/8/LLGo 5.011 ns/op +0.271 ns/op / +5.7% (worse)
Windows MinGW BenchmarkStringEquality/bytes/first/1024/Go 6.024 ns/op +0.09 ns/op / +1.5% (worse)
Windows MinGW BenchmarkStringEquality/bytes/first/1024/LLGo 4.334 ns/op +0.618 ns/op / +16.6% (worse)
Windows MinGW BenchmarkStringEquality/bytes/first/128/Go 5.974 ns/op +0.007 ns/op / +0.1% (worse)
Windows MinGW BenchmarkStringEquality/bytes/first/128/LLGo 4.328 ns/op +0.623 ns/op / +16.8% (worse)
Windows MinGW BenchmarkStringEquality/bytes/first/8/Go 5.980 ns/op +0.079 ns/op / +1.3% (worse)
Windows MinGW BenchmarkStringEquality/bytes/first/8/LLGo 4.325 ns/op +0.617 ns/op / +16.6% (worse)
Windows MinGW BenchmarkStringEquality/bytes/last/1024/Go 19.650 ns/op +0.25 ns/op / +1.3% (worse)
Windows MinGW BenchmarkStringEquality/bytes/last/1024/LLGo 51.560 ns/op +10.61 ns/op / +25.9% (worse)
Windows MinGW BenchmarkStringEquality/bytes/last/128/Go 6.630 ns/op -0.013 ns/op / -0.2% (better)
Windows MinGW BenchmarkStringEquality/bytes/last/128/LLGo 11.150 ns/op +0.43 ns/op / +4.0% (worse)
Windows MinGW BenchmarkStringEquality/bytes/last/8/Go 5.861 ns/op -0.016 ns/op / -0.3% (better)
Windows MinGW BenchmarkStringEquality/bytes/last/8/LLGo 5.098 ns/op +0.77 ns/op / +17.8% (worse)
Windows MinGW BenchmarkStringEquality/strings/equal/1024/Go 20.120 ns/op +0.07 ns/op / +0.3% (worse)
Windows MinGW BenchmarkStringEquality/strings/equal/1024/LLGo 37.140 ns/op -1.55 ns/op / -4.0% (better)
Windows MinGW BenchmarkStringEquality/strings/equal/128/Go 7.438 ns/op -0.043 ns/op / -0.6% (better)
Windows MinGW BenchmarkStringEquality/strings/equal/128/LLGo 7.059 ns/op -0.374 ns/op / -5.0% (better)
Windows MinGW BenchmarkStringEquality/strings/equal/8/Go 5.921 ns/op -0.566 ns/op / -8.7% (better)
Windows MinGW BenchmarkStringEquality/strings/equal/8/LLGo 3.550 ns/op +0.157 ns/op / +4.6% (worse)
Windows MinGW BenchmarkStringEquality/strings/first/1024/Go 5.963 ns/op +0.021 ns/op / +0.4% (worse)
Windows MinGW BenchmarkStringEquality/strings/first/1024/LLGo 2.472 ns/op -0.306 ns/op / -11.0% (better)
Windows MinGW BenchmarkStringEquality/strings/first/128/Go 5.897 ns/op -0.053 ns/op / -0.9% (better)
Windows MinGW BenchmarkStringEquality/strings/first/128/LLGo 2.476 ns/op -0.364 ns/op / -12.8% (better)
Windows MinGW BenchmarkStringEquality/strings/first/8/Go 6.009 ns/op -0.046 ns/op / -0.8% (better)
Windows MinGW BenchmarkStringEquality/strings/first/8/LLGo 2.471 ns/op -0.311 ns/op / -11.2% (better)
Windows MinGW BenchmarkStringEquality/strings/last/1024/Go 19.470 ns/op +0.04 ns/op / +0.2% (worse)
Windows MinGW BenchmarkStringEquality/strings/last/1024/LLGo 41.420 ns/op +3.37 ns/op / +8.9% (worse)
Windows MinGW BenchmarkStringEquality/strings/last/128/Go 6.582 ns/op -0.92 ns/op / -12.3% (better)
Windows MinGW BenchmarkStringEquality/strings/last/128/LLGo 6.719 ns/op -0.331 ns/op / -4.7% (better)
Windows MinGW BenchmarkStringEquality/strings/last/8/Go 5.981 ns/op +0.106 ns/op / +1.8% (worse)
Windows MinGW BenchmarkStringEquality/strings/last/8/LLGo 3.086 ns/op -0.341 ns/op / -10.0% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/equal/1024/Go 30.790 ns/op -0.24 ns/op / -0.8% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/equal/1024/LLGo 33.520 ns/op +0.11 ns/op / +0.3% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/equal/128/Go 10.150 ns/op -0.9 ns/op / -8.1% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/equal/128/LLGo 8.108 ns/op +0.092 ns/op / +1.1% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/equal/8/Go 7.387 ns/op +0.031 ns/op / +0.4% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/equal/8/LLGo 4.794 ns/op +0.165 ns/op / +3.6% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/first/1024/Go 8.090 ns/op -0.038 ns/op / -0.5% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/first/1024/LLGo 3.725 ns/op +0.051 ns/op / +1.4% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/first/128/Go 8.233 ns/op +0.152 ns/op / +1.9% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/first/128/LLGo 3.694 ns/op +0.009 ns/op / +0.2% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/first/8/Go 6.950 ns/op +0.058 ns/op / +0.8% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/first/8/LLGo 3.861 ns/op +0.058 ns/op / +1.5% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/last/1024/Go 30.360 ns/op +0.14 ns/op / +0.5% (worse)
Windows MinGW 386 BenchmarkStringEquality/bytes/last/1024/LLGo 32.840 ns/op -0.05 ns/op / -0.2% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/last/128/Go 9.467 ns/op -0.047 ns/op / -0.5% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/last/128/LLGo 7.116 ns/op -0.148 ns/op / -2.0% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/last/8/Go 7.387 ns/op -0.101 ns/op / -1.3% (better)
Windows MinGW 386 BenchmarkStringEquality/bytes/last/8/LLGo 4.306 ns/op +0.023 ns/op / +0.5% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/equal/1024/Go 28.470 ns/op -0.04 ns/op / -0.1% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/equal/1024/LLGo 33.750 ns/op -0.07 ns/op / -0.2% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/equal/128/Go 9.547 ns/op -0.413 ns/op / -4.1% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/equal/128/LLGo 8.188 ns/op -0.003 ns/op / -0.03663% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/equal/8/Go 7.506 ns/op -0.491 ns/op / -6.1% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/equal/8/LLGo 5.199 ns/op +0.175 ns/op / +3.5% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/first/1024/Go 7.693 ns/op -0.044 ns/op / -0.6% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/first/1024/LLGo 3.740 ns/op -0.037 ns/op / -1.0% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/first/128/Go 7.857 ns/op +0.137 ns/op / +1.8% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/first/128/LLGo 3.873 ns/op +0.091 ns/op / +2.4% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/first/8/Go 6.881 ns/op +0.024 ns/op / +0.4% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/first/8/LLGo 4.181 ns/op +0.323 ns/op / +8.4% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/last/1024/Go 28.040 ns/op -0.42 ns/op / -1.5% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/last/1024/LLGo 32.860 ns/op +0.05 ns/op / +0.2% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/last/128/Go 9.013 ns/op -0.058 ns/op / -0.6% (better)
Windows MinGW 386 BenchmarkStringEquality/strings/last/128/LLGo 7.288 ns/op +0.106 ns/op / +1.5% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/last/8/Go 7.178 ns/op +0.074 ns/op / +1.0% (worse)
Windows MinGW 386 BenchmarkStringEquality/strings/last/8/LLGo 4.289 ns/op -0.123 ns/op / -2.8% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/equal/1024/Go 31.510 ns/op +0.41 ns/op / +1.3% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/equal/1024/LLGo 38.980 ns/op -0.36 ns/op / -0.9% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/equal/128/Go 6.826 ns/op +0.161 ns/op / +2.4% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/equal/128/LLGo 6.955 ns/op -0.056 ns/op / -0.8% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/equal/8/Go 3.724 ns/op -0.021 ns/op / -0.6% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/equal/8/LLGo 2.542 ns/op -0.348 ns/op / -12.0% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/first/1024/Go 4.735 ns/op -0.025 ns/op / -0.5% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/first/1024/LLGo 1.733 ns/op -0.001 ns/op / -0.1% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/first/128/Go 4.874 ns/op -0.002 ns/op / -0.04102% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/first/128/LLGo 1.723 ns/op -0.012 ns/op / -0.7% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/first/8/Go 3.540 ns/op -0.003 ns/op / -0.1% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/first/8/LLGo 1.679 ns/op -0.018 ns/op / -1.1% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/last/1024/Go 31.040 ns/op +0.03 ns/op / +0.1% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/last/1024/LLGo 38.670 ns/op -0.69 ns/op / -1.8% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/last/128/Go 6.715 ns/op +0.009 ns/op / +0.1% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/last/128/LLGo 6.723 ns/op -0.067 ns/op / -1.0% (better)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/last/8/Go 3.552 ns/op +0.195 ns/op / +5.8% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/bytes/last/8/LLGo 2.262 ns/op -0.209 ns/op / -8.5% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/equal/1024/Go 27.350 ns/op -0.13 ns/op / -0.5% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/equal/1024/LLGo 36.140 ns/op -0.31 ns/op / -0.9% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/equal/128/Go 6.075 ns/op +0.018 ns/op / +0.3% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/equal/128/LLGo 5.857 ns/op -0.005 ns/op / -0.1% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/equal/8/Go 3.910 ns/op +0.013 ns/op / +0.3% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/equal/8/LLGo 2.489 ns/op -0.459 ns/op / -15.6% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/first/1024/Go 4.487 ns/op -0.024 ns/op / -0.5% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/first/1024/LLGo 1.613 ns/op -0.071 ns/op / -4.2% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/first/128/Go 4.549 ns/op +0.025 ns/op / +0.6% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/first/128/LLGo 1.549 ns/op -0.168 ns/op / -9.8% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/first/8/Go 3.925 ns/op +0.02 ns/op / +0.5% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/first/8/LLGo 1.597 ns/op -0.142 ns/op / -8.2% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/last/1024/Go 27.130 ns/op -0.12 ns/op / -0.4% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/last/1024/LLGo 35.570 ns/op +0.19 ns/op / +0.5% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/last/128/Go 5.923 ns/op +0.006 ns/op / +0.1% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/last/128/LLGo 5.457 ns/op -0.033 ns/op / -0.6% (better)
Windows MinGW ARM64 BenchmarkStringEquality/strings/last/8/Go 3.913 ns/op +0.027 ns/op / +0.7% (worse)
Windows MinGW ARM64 BenchmarkStringEquality/strings/last/8/LLGo 2.198 ns/op -0.079 ns/op / -3.5% (better)
Windows MSVC BenchmarkStringEquality/bytes/equal/1024/Go 20.090 ns/op -0.11 ns/op / -0.5% (better)
Windows MSVC BenchmarkStringEquality/bytes/equal/1024/LLGo 41.830 ns/op -0.01 ns/op / -0.0239% (better)
Windows MSVC BenchmarkStringEquality/bytes/equal/128/Go 7.457 ns/op -0.005 ns/op / -0.1% (better)
Windows MSVC BenchmarkStringEquality/bytes/equal/128/LLGo 11.010 ns/op -0.17 ns/op / -1.5% (better)
Windows MSVC BenchmarkStringEquality/bytes/equal/8/Go 5.884 ns/op -0.004 ns/op / -0.1% (better)
Windows MSVC BenchmarkStringEquality/bytes/equal/8/LLGo 4.635 ns/op +0.001 ns/op / +0.02158% (worse)
Windows MSVC BenchmarkStringEquality/bytes/first/1024/Go 5.891 ns/op -0.126 ns/op / -2.1% (better)
Windows MSVC BenchmarkStringEquality/bytes/first/1024/LLGo 3.737 ns/op +0.029 ns/op / +0.8% (worse)
Windows MSVC BenchmarkStringEquality/bytes/first/128/Go 5.887 ns/op -0.084 ns/op / -1.4% (better)
Windows MSVC BenchmarkStringEquality/bytes/first/128/LLGo 3.711 ns/op +0.003 ns/op / +0.1% (worse)
Windows MSVC BenchmarkStringEquality/bytes/first/8/Go 5.912 ns/op -0.067 ns/op / -1.1% (better)
Windows MSVC BenchmarkStringEquality/bytes/first/8/LLGo 3.735 ns/op +0.027 ns/op / +0.7% (worse)
Windows MSVC BenchmarkStringEquality/bytes/last/1024/Go 19.340 ns/op -0.12 ns/op / -0.6% (better)
Windows MSVC BenchmarkStringEquality/bytes/last/1024/LLGo 41.210 ns/op +0.26 ns/op / +0.6% (worse)
Windows MSVC BenchmarkStringEquality/bytes/last/128/Go 6.489 ns/op -0.14 ns/op / -2.1% (better)
Windows MSVC BenchmarkStringEquality/bytes/last/128/LLGo 10.880 ns/op +0.05 ns/op / +0.5% (worse)
Windows MSVC BenchmarkStringEquality/bytes/last/8/Go 5.902 ns/op -0.01 ns/op / -0.2% (better)
Windows MSVC BenchmarkStringEquality/bytes/last/8/LLGo 4.375 ns/op +0.041 ns/op / +0.9% (worse)
Windows MSVC BenchmarkStringEquality/strings/equal/1024/Go 20.120 ns/op -0.53 ns/op / -2.6% (better)
Windows MSVC BenchmarkStringEquality/strings/equal/1024/LLGo 38.720 ns/op +0.03 ns/op / +0.1% (worse)
Windows MSVC BenchmarkStringEquality/strings/equal/128/Go 7.533 ns/op +0.016 ns/op / +0.2% (worse)
Windows MSVC BenchmarkStringEquality/strings/equal/128/LLGo 7.045 ns/op +0.08 ns/op / +1.1% (worse)
Windows MSVC BenchmarkStringEquality/strings/equal/8/Go 5.907 ns/op -0.185 ns/op / -3.0% (better)
Windows MSVC BenchmarkStringEquality/strings/equal/8/LLGo 3.491 ns/op +0.08 ns/op / +2.3% (worse)
Windows MSVC BenchmarkStringEquality/strings/first/1024/Go 5.947 ns/op -0.083 ns/op / -1.4% (better)
Windows MSVC BenchmarkStringEquality/strings/first/1024/LLGo 2.788 ns/op +0.009 ns/op / +0.3% (worse)
Windows MSVC BenchmarkStringEquality/strings/first/128/Go 5.886 ns/op +0.006 ns/op / +0.1% (worse)
Windows MSVC BenchmarkStringEquality/strings/first/128/LLGo 3.098 ns/op +0.275 ns/op / +9.7% (worse)
Windows MSVC BenchmarkStringEquality/strings/first/8/Go 5.879 ns/op -0.102 ns/op / -1.7% (better)
Windows MSVC BenchmarkStringEquality/strings/first/8/LLGo 2.779 ns/op 0 ns/op / +0.0%
Windows MSVC BenchmarkStringEquality/strings/last/1024/Go 19.340 ns/op -0.17 ns/op / -0.9% (better)
Windows MSVC BenchmarkStringEquality/strings/last/1024/LLGo 38.090 ns/op -0.01 ns/op / -0.02625% (better)
Windows MSVC BenchmarkStringEquality/strings/last/128/Go 6.625 ns/op -0.003 ns/op / -0.04526% (better)
Windows MSVC BenchmarkStringEquality/strings/last/128/LLGo 6.920 ns/op -0.029 ns/op / -0.4% (better)
Windows MSVC BenchmarkStringEquality/strings/last/8/Go 5.880 ns/op -0.085 ns/op / -1.4% (better)
Windows MSVC BenchmarkStringEquality/strings/last/8/LLGo 3.536 ns/op +0.088 ns/op / +2.6% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/equal/1024/Go 30.870 ns/op +0.05 ns/op / +0.2% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/equal/1024/LLGo 85 ns/op +0.35 ns/op / +0.4% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/equal/128/Go 9.841 ns/op -0.083 ns/op / -0.8% (better)
Windows MSVC 386 BenchmarkStringEquality/bytes/equal/128/LLGo 16.210 ns/op -0.06 ns/op / -0.4% (better)
Windows MSVC 386 BenchmarkStringEquality/bytes/equal/8/Go 7.361 ns/op +0.037 ns/op / +0.5% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/equal/8/LLGo 5.290 ns/op -0.158 ns/op / -2.9% (better)
Windows MSVC 386 BenchmarkStringEquality/bytes/first/1024/Go 8.111 ns/op +0.007 ns/op / +0.1% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/first/1024/LLGo 4.016 ns/op +0.003 ns/op / +0.1% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/first/128/Go 8.334 ns/op +0.257 ns/op / +3.2% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/first/128/LLGo 4.028 ns/op +0.016 ns/op / +0.4% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/first/8/Go 7.032 ns/op +0.089 ns/op / +1.3% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/first/8/LLGo 4.107 ns/op +0.041 ns/op / +1.0% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/last/1024/Go 30.360 ns/op -0.03 ns/op / -0.1% (better)
Windows MSVC 386 BenchmarkStringEquality/bytes/last/1024/LLGo 84.470 ns/op -0.09 ns/op / -0.1% (better)
Windows MSVC 386 BenchmarkStringEquality/bytes/last/128/Go 9.516 ns/op +0.094 ns/op / +1.0% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/last/128/LLGo 15.730 ns/op -0.01 ns/op / -0.1% (better)
Windows MSVC 386 BenchmarkStringEquality/bytes/last/8/Go 7.476 ns/op +0.006 ns/op / +0.1% (worse)
Windows MSVC 386 BenchmarkStringEquality/bytes/last/8/LLGo 4.666 ns/op -0.021 ns/op / -0.4% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/equal/1024/Go 28.780 ns/op +0.15 ns/op / +0.5% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/equal/1024/LLGo 94.200 ns/op +0.03 ns/op / +0.03186% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/equal/128/Go 9.493 ns/op -0.075 ns/op / -0.8% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/equal/128/LLGo 16.410 ns/op +0.04 ns/op / +0.2% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/equal/8/Go 8.088 ns/op +0.82 ns/op / +11.3% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/equal/8/LLGo 5.001 ns/op +0.058 ns/op / +1.2% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/first/1024/Go 7.874 ns/op -0.033 ns/op / -0.4% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/first/1024/LLGo 3.705 ns/op -0.008 ns/op / -0.2% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/first/128/Go 7.785 ns/op +0.023 ns/op / +0.3% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/first/128/LLGo 3.711 ns/op -0.012 ns/op / -0.3% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/first/8/Go 6.854 ns/op -0.137 ns/op / -2.0% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/first/8/LLGo 3.774 ns/op -0.014 ns/op / -0.4% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/last/1024/Go 28.120 ns/op -0.01 ns/op / -0.03555% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/last/1024/LLGo 93.660 ns/op +0.2 ns/op / +0.2% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/last/128/Go 8.989 ns/op -0.078 ns/op / -0.9% (better)
Windows MSVC 386 BenchmarkStringEquality/strings/last/128/LLGo 16.190 ns/op +0.12 ns/op / +0.7% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/last/8/Go 7.154 ns/op +0.034 ns/op / +0.5% (worse)
Windows MSVC 386 BenchmarkStringEquality/strings/last/8/LLGo 4.673 ns/op +0.027 ns/op / +0.6% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/equal/1024/Go 31.280 ns/op +0.11 ns/op / +0.4% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/equal/1024/LLGo 39.250 ns/op -0.18 ns/op / -0.5% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/equal/128/Go 6.720 ns/op +0.015 ns/op / +0.2% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/equal/128/LLGo 6.992 ns/op -0.048 ns/op / -0.7% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/equal/8/Go 3.719 ns/op -0.003 ns/op / -0.1% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/equal/8/LLGo 2.703 ns/op -0.15 ns/op / -5.3% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/first/1024/Go 4.744 ns/op -0.016 ns/op / -0.3% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/first/1024/LLGo 1.715 ns/op -0.083 ns/op / -4.6% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/first/128/Go 4.764 ns/op -0.01 ns/op / -0.2% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/first/128/LLGo 1.719 ns/op -0.16 ns/op / -8.5% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/first/8/Go 3.546 ns/op +0.116 ns/op / +3.4% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/first/8/LLGo 1.677 ns/op -0.127 ns/op / -7.0% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/last/1024/Go 31.010 ns/op -0.02 ns/op / -0.1% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/last/1024/LLGo 39 ns/op +0.29 ns/op / +0.7% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/last/128/Go 6.668 ns/op +0.019 ns/op / +0.3% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/last/128/LLGo 6.764 ns/op +0.001 ns/op / +0.01479% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/last/8/Go 3.544 ns/op -0.006 ns/op / -0.2% (better)
Windows MSVC ARM64 BenchmarkStringEquality/bytes/last/8/LLGo 2.357 ns/op -0.146 ns/op / -5.8% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/equal/1024/Go 27.390 ns/op 0 ns/op / +0.0%
Windows MSVC ARM64 BenchmarkStringEquality/strings/equal/1024/LLGo 36.210 ns/op +0.17 ns/op / +0.5% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/equal/128/Go 6.091 ns/op -0.008 ns/op / -0.1% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/equal/128/LLGo 5.943 ns/op +0.062 ns/op / +1.1% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/equal/8/Go 3.885 ns/op -0.016 ns/op / -0.4% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/equal/8/LLGo 2.742 ns/op +0.336 ns/op / +14.0% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/first/1024/Go 4.515 ns/op +0.022 ns/op / +0.5% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/first/1024/LLGo 1.531 ns/op -0.088 ns/op / -5.4% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/first/128/Go 4.526 ns/op -0.024 ns/op / -0.5% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/first/128/LLGo 1.561 ns/op -0.024 ns/op / -1.5% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/first/8/Go 3.862 ns/op +0.007 ns/op / +0.2% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/first/8/LLGo 1.627 ns/op +0.021 ns/op / +1.3% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/last/1024/Go 27.090 ns/op 0 ns/op / +0.0%
Windows MSVC ARM64 BenchmarkStringEquality/strings/last/1024/LLGo 35.410 ns/op +0.04 ns/op / +0.1% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/last/128/Go 5.925 ns/op +0.012 ns/op / +0.2% (worse)
Windows MSVC ARM64 BenchmarkStringEquality/strings/last/128/LLGo 5.459 ns/op -0.013 ns/op / -0.2% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/last/8/Go 3.879 ns/op -0.001 ns/op / -0.02577% (better)
Windows MSVC ARM64 BenchmarkStringEquality/strings/last/8/LLGo 2.281 ns/op +0.33 ns/op / +16.9% (worse)

Program measurements

Platform Workload File size vs base Text size vs base Build vs base Run vs base
Linux cprintf 8576 B 0 B / +0.0% 387 B 0 B / +0.0% 1.097 s -169.2 ms / -13.4% (better) 1.344 ms -191.4 us / -12.5% (better)
Linux cprintf-lto 8240 B 0 B / +0.0% 368 B 0 B / +0.0% 1.164 s -118.9 ms / -9.3% (better) 1.296 ms -280 us / -17.8% (better)
Linux fmtprintf 1945040 B +512 B / +0.02633% (worse) 269899 B -16 B / -0.005928% (better) 7.191 s -148.4 ms / -2.0% (better) 3.251 ms -351.4 us / -9.8% (better)
Linux fmtprintf-lto 1132896 B +528 B / +0.04663% (worse) 220220 B -422 B / -0.2% (better) 17.028 s -1.091 s / -6.0% (better) 4.118 ms +649.1 us / +18.7% (worse)
Linux println 261768 B +400 B / +0.2% (worse) 19132 B -6 B / -0.03135% (better) 1.165 s -234 ms / -16.7% (better) 1.598 ms -428.3 us / -21.1% (better)
Linux println-lto 102920 B -56 B / -0.1% (better) 15723 B 0 B / +0.0% 1.880 s -339.3 ms / -15.3% (better) 1.635 ms -384.3 us / -19.0% (better)
macOS cprintf 50944 B 0 B / +0.0% 4409 B 0 B / +0.0% 1.466 s +110 ms / +8.1% (worse) 4.301 ms -2.025 ms / -32.0% (better)
macOS cprintf-lto 50608 B 0 B / +0.0% 161 B 0 B / +0.0% 1.517 s +259.5 ms / +20.6% (worse) 5.008 ms +2.329 ms / +86.9% (worse)
macOS fmtprintf 1233696 B 0 B / +0.0% 676005 B +52 B / +0.007693% (worse) 7.862 s +1.49 s / +23.4% (worse) 7.255 ms +529.5 us / +7.9% (worse)
macOS fmtprintf-lto 871584 B -16 B / -0.001836% (better) 520849 B -308 B / -0.1% (better) 9.588 s +1.19 s / +14.2% (worse) 7.301 ms +900.1 us / +14.1% (worse)
macOS println 100592 B 0 B / +0.0% 26327 B -12 B / -0.04556% (better) 1.606 s +445 ms / +38.3% (worse) 5.439 ms +1.746 ms / +47.3% (worse)
macOS println-lto 85632 B 0 B / +0.0% 22487 B 0 B / +0.0% 1.839 s +135.8 ms / +8.0% (worse) 6.285 ms +1.827 ms / +41.0% (worse)
Windows MinGW cprintf 750080 B +512 B / +0.1% (worse) 4230 B 0 B / +0.0% 2.132 s +13.57 ms / +0.6% (worse) 3.883 ms -156.7 us / -3.9% (better)
Windows MinGW cprintf-lto 60928 B 0 B / +0.0% 4182 B 0 B / +0.0% 2.152 s -94.1 ms / -4.2% (better) 3.407 ms -571.9 us / -14.4% (better)
Windows MinGW fmtprintf 5160448 B +1024 B / +0.01985% (worse) 361894 B -16 B / -0.004421% (better) 7.202 s -15.86 ms / -0.2% (better) 10.082 ms -972.3 us / -8.8% (better)
Windows MinGW fmtprintf-lto 2799104 B +12800 B / +0.5% (worse) 306406 B -624 B / -0.2% (better) 11.971 s +389 ms / +3.4% (worse) 10.988 ms -407.5 us / -3.6% (better)
Windows MinGW println 812544 B +1024 B / +0.1% (worse) 27382 B 0 B / +0.0% 2.140 s -73.79 ms / -3.3% (better) 7.082 ms -1.248 ms / -15.0% (better)
Windows MinGW println-lto 233984 B +512 B / +0.2% (worse) 22774 B 0 B / +0.0% 2.418 s -109.5 ms / -4.3% (better) 8.508 ms +978.5 us / +13.0% (worse)
Windows MinGW 386 cprintf 756736 B +2048 B / +0.3% (worse) 22678 B -16 B / -0.1% (better) 2.056 s +956.6 us / +0.04655% (worse) 8.355 ms -1.346 ms / -13.9% (better)
Windows MinGW 386 cprintf-lto 281600 B -1024 B / -0.4% (better) 19476 B 0 B / +0.0% 2.310 s -71.33 ms / -3.0% (better) 8.688 ms -220.9 us / -2.5% (better)
Windows MinGW 386 fmtprintf 4511744 B +1536 B / +0.03406% (worse) 284800 B -32 B / -0.01123% (better) 6.775 s -71 ms / -1.0% (better) 11.403 ms -413.4 us / -3.5% (better)
Windows MinGW 386 fmtprintf-lto 2900992 B -2048 B / -0.1% (better) 256074 B -632 B / -0.2% (better) 11.703 s +708.7 ms / +6.4% (worse) 13.353 ms +1.746 ms / +15.0% (worse)
Windows MinGW 386 println 755712 B +2560 B / +0.3% (worse) 22624 B 0 B / +0.0% 2.036 s +55.46 ms / +2.8% (worse) 8.898 ms +135 us / +1.5% (worse)
Windows MinGW 386 println-lto 280576 B -1536 B / -0.5% (better) 19410 B 0 B / +0.0% 2.349 s +42.43 ms / +1.8% (worse) 10.488 ms +1.75 ms / +20.0% (worse)
Windows MinGW ARM64 cprintf 757248 B +1024 B / +0.1% (worse) 4028 B 0 B / +0.0% 2.211 s +56.66 ms / +2.6% (worse) 6.678 ms +329.8 us / +5.2% (worse)
Windows MinGW ARM64 cprintf-lto 60416 B 0 B / +0.0% 3984 B 0 B / +0.0% 2.256 s +47.15 ms / +2.1% (worse) 6.445 ms +67.7 us / +1.1% (worse)
Windows MinGW ARM64 fmtprintf 5097472 B +512 B / +0.01005% (worse) 302040 B -16 B / -0.005297% (better) 6.489 s -75.42 ms / -1.1% (better) 13.358 ms -4.372 ms / -24.7% (better)
Windows MinGW ARM64 fmtprintf-lto 2912768 B +9728 B / +0.3% (worse) 263416 B -360 B / -0.1% (better) 10.198 s +64.6 ms / +0.6% (worse) 14.222 ms +655.9 us / +4.8% (worse)
Windows MinGW ARM64 println 817664 B +1024 B / +0.1% (worse) 25560 B -8 B / -0.03129% (better) 2.198 s +25.34 ms / +1.2% (worse) 10.773 ms -286 us / -2.6% (better)
Windows MinGW ARM64 println-lto 236544 B -512 B / -0.2% (better) 21880 B 0 B / +0.0% 2.482 s +46.04 ms / +1.9% (worse) 11.219 ms +661.4 us / +6.3% (worse)
Windows MSVC cprintf 994816 B +1024 B / +0.1% (worse) 66003 B 0 B / +0.0% 1.952 s -180.2 ms / -8.5% (better) 3.548 ms -605.2 us / -14.6% (better)
Windows MSVC cprintf-lto 308736 B 0 B / +0.0% 65971 B 0 B / +0.0% 2.009 s -62.9 ms / -3.0% (better) 3.920 ms +251.4 us / +6.9% (worse)
Windows MSVC fmtprintf 5460480 B +512 B / +0.009377% (worse) 457990 B 0 B / +0.0% 6.523 s -395.8 ms / -5.7% (better) 11.525 ms -931.3 us / -7.5% (better)
Windows MSVC fmtprintf-lto 3123200 B +13312 B / +0.4% (worse) 404902 B -592 B / -0.1% (better) 10.252 s -492.1 ms / -4.6% (better) 10.519 ms -1.338 ms / -11.3% (better)
Windows MSVC println 1126912 B +1024 B / +0.1% (worse) 123526 B 0 B / +0.0% 1.985 s -63.31 ms / -3.1% (better) 7.003 ms -738.1 us / -9.5% (better)
Windows MSVC println-lto 553984 B 0 B / +0.0% 119446 B 0 B / +0.0% 2.172 s -145.4 ms / -6.3% (better) 7.135 ms -2.515 ms / -26.1% (better)
Windows MSVC 386 cprintf 665088 B +1024 B / +0.2% (worse) 21330 B 0 B / +0.0% 1.969 s -316.5 ms / -13.9% (better) 10.111 ms -821.6 us / -7.5% (better)
Windows MSVC 386 cprintf-lto 221184 B -512 B / -0.2% (better) 18825 B 0 B / +0.0% 2.234 s -142.1 ms / -6.0% (better) 9.556 ms +193.2 us / +2.1% (worse)
Windows MSVC 386 fmtprintf 4238336 B 0 B / +0.0% 268278 B -16 B / -0.005964% (better) 6.771 s -145.7 ms / -2.1% (better) 13.600 ms -538.6 us / -3.8% (better)
Windows MSVC 386 fmtprintf-lto 2714112 B -3072 B / -0.1% (better) 235809 B -400 B / -0.2% (better) 10.718 s +334 ms / +3.2% (worse) 13.669 ms +1.238 ms / +10.0% (worse)
Windows MSVC 386 println 663040 B +1024 B / +0.2% (worse) 21260 B -16 B / -0.1% (better) 1.954 s -62.56 ms / -3.1% (better) 10.084 ms -363.6 us / -3.5% (better)
Windows MSVC 386 println-lto 220160 B 0 B / +0.0% 18755 B 0 B / +0.0% 2.252 s -52.26 ms / -2.3% (better) 10.105 ms -492.1 us / -4.6% (better)
Windows MSVC ARM64 cprintf 759808 B +1024 B / +0.1% (worse) 4240 B 0 B / +0.0% 2.050 s +24.12 ms / +1.2% (worse) 7.567 ms +267.5 us / +3.7% (worse)
Windows MSVC ARM64 cprintf-lto 66048 B 0 B / +0.0% 4140 B 0 B / +0.0% 2.085 s +34.01 ms / +1.7% (worse) 7.550 ms +146.7 us / +2.0% (worse)
Windows MSVC ARM64 fmtprintf 5093888 B +512 B / +0.01005% (worse) 302364 B -16 B / -0.005291% (better) 6.536 s +64.22 ms / +1.0% (worse) 16.790 ms +603.2 us / +3.7% (worse)
Windows MSVC ARM64 fmtprintf-lto 2920448 B +9728 B / +0.3% (worse) 264368 B -352 B / -0.1% (better) 10.232 s +137.4 ms / +1.4% (worse) 17.706 ms +712.4 us / +4.2% (worse)
Windows MSVC ARM64 println 820736 B +1536 B / +0.2% (worse) 26052 B 0 B / +0.0% 2.033 s +20.59 ms / +1.0% (worse) 12.434 ms +43.6 us / +0.4% (worse)
Windows MSVC ARM64 println-lto 242688 B 0 B / +0.0% 22432 B 0 B / +0.0% 2.325 s +43.38 ms / +1.9% (worse) 13.393 ms -38.3 us / -0.3% (better)
Core language and compiler benchmarks
Platform Benchmark ns/op vs base
Linux BenchmarkLookupPCRandom 14.560 ns/op -0.03 ns/op / -0.2% (better)
Linux BenchmarkMergeCompilerFlags 198.700 ns/op -9.1 ns/op / -4.4% (better)
Linux BenchmarkMergeLinkerFlags 129.800 ns/op -7.7 ns/op / -5.6% (better)
Linux BenchmarkChannelBuffered 72 ns/op -0.23 ns/op / -0.3% (better)
Linux BenchmarkChannelHandoff 13420 ns/op -1678 ns/op / -11.1% (better)
Linux BenchmarkDefer 16.870 ns/op +0.88 ns/op / +5.5% (worse)
Linux BenchmarkDirectCall 1.167 ns/op -0.011 ns/op / -0.9% (better)
Linux BenchmarkGlobalRead 1.943 ns/op -0.001 ns/op / -0.1% (better)
Linux BenchmarkGlobalWrite 7.766 ns/op -0.012 ns/op / -0.2% (better)
Linux BenchmarkGoroutine 29260 ns/op -2624 ns/op / -8.2% (better)
Linux BenchmarkInterfaceCall 5.045 ns/op +0.326 ns/op / +6.9% (worse)
Linux BenchmarkRuntimeGetG 2.405 ns/op -0.049 ns/op / -2.0% (better)
macOS BenchmarkLookupPCRandom 15.910 ns/op +2.48 ns/op / +18.5% (worse)
macOS BenchmarkMergeCompilerFlags 112.900 ns/op +7.2 ns/op / +6.8% (worse)
macOS BenchmarkMergeLinkerFlags 75.830 ns/op -1.09 ns/op / -1.4% (better)
macOS BenchmarkChannelBuffered 33.460 ns/op -4.21 ns/op / -11.2% (better)
macOS BenchmarkChannelHandoff 8017 ns/op -5423 ns/op / -40.3% (better)
macOS BenchmarkDefer 18.720 ns/op +3.31 ns/op / +21.5% (worse)
macOS BenchmarkDirectCall 1.163 ns/op 0 ns/op / +0.0%
macOS BenchmarkGlobalRead 1.157 ns/op -0.034 ns/op / -2.9% (better)
macOS BenchmarkGlobalWrite 1.278 ns/op +0.041 ns/op / +3.3% (worse)
macOS BenchmarkGoroutine 48821 ns/op -15494 ns/op / -24.1% (better)
macOS BenchmarkInterfaceCall 4.308 ns/op +0.009 ns/op / +0.2% (worse)
macOS BenchmarkRuntimeGetG 2.075 ns/op -0.777 ns/op / -27.2% (better)
Windows MinGW BenchmarkLookupPCRandom 13.030 ns/op -0.06 ns/op / -0.5% (better)
Windows MinGW BenchmarkMergeCompilerFlags 642.600 ns/op +2.7 ns/op / +0.4% (worse)
Windows MinGW BenchmarkMergeLinkerFlags 543.200 ns/op -7.1 ns/op / -1.3% (better)
Windows MinGW BenchmarkChannelBuffered 35.620 ns/op +0.82 ns/op / +2.4% (worse)
Windows MinGW BenchmarkChannelHandoff 586.900 ns/op -13 ns/op / -2.2% (better)
Windows MinGW BenchmarkDefer 14.360 ns/op -0.54 ns/op / -3.6% (better)
Windows MinGW BenchmarkDirectCall 1.859 ns/op -0.002 ns/op / -0.1% (better)
Windows MinGW BenchmarkGlobalRead 1.551 ns/op +0.002 ns/op / +0.1% (worse)
Windows MinGW BenchmarkGlobalWrite 2.471 ns/op 0 ns/op / +0.0%
Windows MinGW BenchmarkGoroutine 95368 ns/op -1492 ns/op / -1.5% (better)
Windows MinGW BenchmarkInterfaceCall 7.447 ns/op +0.006 ns/op / +0.1% (worse)
Windows MinGW BenchmarkRuntimeGetG 1.857 ns/op -0.314 ns/op / -14.5% (better)
Windows MinGW 386 BenchmarkLookupPCRandom 26.690 ns/op +0.02 ns/op / +0.1% (worse)
Windows MinGW 386 BenchmarkMergeCompilerFlags 779.500 ns/op +22.5 ns/op / +3.0% (worse)
Windows MinGW 386 BenchmarkMergeLinkerFlags 740.700 ns/op +58 ns/op / +8.5% (worse)
Windows MinGW 386 BenchmarkChannelBuffered 44.060 ns/op -0.26 ns/op / -0.6% (better)
Windows MinGW 386 BenchmarkChannelHandoff 580.500 ns/op +20.5 ns/op / +3.7% (worse)
Windows MinGW 386 BenchmarkDefer 15.220 ns/op +0.94 ns/op / +6.6% (worse)
Windows MinGW 386 BenchmarkDirectCall 1.550 ns/op +0.001 ns/op / +0.1% (worse)
Windows MinGW 386 BenchmarkGlobalRead 1.553 ns/op +0.003 ns/op / +0.2% (worse)
Windows MinGW 386 BenchmarkGlobalWrite 7.776 ns/op -0.007 ns/op / -0.1% (better)
Windows MinGW 386 BenchmarkGoroutine 109859 ns/op +2033 ns/op / +1.9% (worse)
Windows MinGW 386 BenchmarkInterfaceCall 7.451 ns/op +0.009 ns/op / +0.1% (worse)
Windows MinGW 386 BenchmarkRuntimeGetG 2.175 ns/op +0.251 ns/op / +13.0% (worse)
Windows MinGW ARM64 BenchmarkLookupPCRandom 11.990 ns/op -0.09 ns/op / -0.7% (better)
Windows MinGW ARM64 BenchmarkMergeCompilerFlags 577.400 ns/op +5.1 ns/op / +0.9% (worse)
Windows MinGW ARM64 BenchmarkMergeLinkerFlags 574.200 ns/op +52.3 ns/op / +10.0% (worse)
Windows MinGW ARM64 BenchmarkChannelBuffered 43.830 ns/op +0.46 ns/op / +1.1% (worse)
Windows MinGW ARM64 BenchmarkChannelHandoff 1806 ns/op -41 ns/op / -2.2% (better)
Windows MinGW ARM64 BenchmarkDefer 11.820 ns/op -0.01 ns/op / -0.1% (better)
Windows MinGW ARM64 BenchmarkDirectCall 0.663 ns/op 0 ns/op / +0.0%
Windows MinGW ARM64 BenchmarkGlobalRead 0.590 ns/op +0.0001 ns/op / +0.01696% (worse)
Windows MinGW ARM64 BenchmarkGlobalWrite 0.885 ns/op +0.0002 ns/op / +0.02261% (worse)
Windows MinGW ARM64 BenchmarkGoroutine 61305 ns/op -2143 ns/op / -3.4% (better)
Windows MinGW ARM64 BenchmarkInterfaceCall 3.867 ns/op -0.003 ns/op / -0.1% (better)
Windows MinGW ARM64 BenchmarkRuntimeGetG 1.801 ns/op +0.032 ns/op / +1.8% (worse)
Windows MSVC BenchmarkLookupPCRandom 13.120 ns/op -0.08 ns/op / -0.6% (better)
Windows MSVC BenchmarkMergeCompilerFlags 605.900 ns/op -24.9 ns/op / -3.9% (better)
Windows MSVC BenchmarkMergeLinkerFlags 534.200 ns/op -13.6 ns/op / -2.5% (better)
Windows MSVC BenchmarkChannelBuffered 32.760 ns/op -0.56 ns/op / -1.7% (better)
Windows MSVC BenchmarkChannelHandoff 639.300 ns/op -36.3 ns/op / -5.4% (better)
Windows MSVC BenchmarkDefer 13.940 ns/op -0.03 ns/op / -0.2% (better)
Windows MSVC BenchmarkDirectCall 1.859 ns/op +0.003 ns/op / +0.2% (worse)
Windows MSVC BenchmarkGlobalRead 1.549 ns/op 0 ns/op / +0.0%
Windows MSVC BenchmarkGlobalWrite 2.471 ns/op +0.001 ns/op / +0.04049% (worse)
Windows MSVC BenchmarkGoroutine 87978 ns/op -2 ns/op / -0.002273% (better)
Windows MSVC BenchmarkInterfaceCall 7.141 ns/op 0 ns/op / +0.0%
Windows MSVC BenchmarkRuntimeGetG 2.481 ns/op -0.002 ns/op / -0.1% (better)
Windows MSVC 386 BenchmarkLookupPCRandom 26.590 ns/op +0.06 ns/op / +0.2% (worse)
Windows MSVC 386 BenchmarkMergeCompilerFlags 722.100 ns/op -53.3 ns/op / -6.9% (better)
Windows MSVC 386 BenchmarkMergeLinkerFlags 680.700 ns/op -28.5 ns/op / -4.0% (better)
Windows MSVC 386 BenchmarkChannelBuffered 43.740 ns/op +0.4 ns/op / +0.9% (worse)
Windows MSVC 386 BenchmarkChannelHandoff 624 ns/op -41.4 ns/op / -6.2% (better)
Windows MSVC 386 BenchmarkDefer 15.190 ns/op +0.6 ns/op / +4.1% (worse)
Windows MSVC 386 BenchmarkDirectCall 1.550 ns/op +0.001 ns/op / +0.1% (worse)
Windows MSVC 386 BenchmarkGlobalRead 1.863 ns/op +0.003 ns/op / +0.2% (worse)
Windows MSVC 386 BenchmarkGlobalWrite 7.788 ns/op 0 ns/op / +0.0%
Windows MSVC 386 BenchmarkGoroutine 107973 ns/op +591 ns/op / +0.6% (worse)
Windows MSVC 386 BenchmarkInterfaceCall 7.460 ns/op +0.296 ns/op / +4.1% (worse)
Windows MSVC 386 BenchmarkRuntimeGetG 2.169 ns/op +0.243 ns/op / +12.6% (worse)
Windows MSVC ARM64 BenchmarkLookupPCRandom 12.110 ns/op +0.01 ns/op / +0.1% (worse)
Windows MSVC ARM64 BenchmarkMergeCompilerFlags 579.100 ns/op -5.1 ns/op / -0.9% (better)
Windows MSVC ARM64 BenchmarkMergeLinkerFlags 542.400 ns/op -2.2 ns/op / -0.4% (better)
Windows MSVC ARM64 BenchmarkChannelBuffered 46.080 ns/op -0.22 ns/op / -0.5% (better)
Windows MSVC ARM64 BenchmarkChannelHandoff 1369 ns/op -16 ns/op / -1.2% (better)
Windows MSVC ARM64 BenchmarkDefer 11.810 ns/op +0.06 ns/op / +0.5% (worse)
Windows MSVC ARM64 BenchmarkDirectCall 0.590 ns/op +0.0003 ns/op / +0.1% (worse)
Windows MSVC ARM64 BenchmarkGlobalRead 0.664 ns/op +0.0006 ns/op / +0.1% (worse)
Windows MSVC ARM64 BenchmarkGlobalWrite 3.758 ns/op +0.006 ns/op / +0.2% (worse)
Windows MSVC ARM64 BenchmarkGoroutine 59721 ns/op -141 ns/op / -0.2% (better)
Windows MSVC ARM64 BenchmarkInterfaceCall 3.848 ns/op +0.004 ns/op / +0.1% (worse)
Windows MSVC ARM64 BenchmarkRuntimeGetG 1.771 ns/op +0.003 ns/op / +0.2% (worse)
Timer runtime benchmarks
Platform Operation and runtime ns/op vs base
Linux AfterFuncZeroDelivery/Go 919.700 ns/op +3.5 ns/op / +0.4% (worse)
Linux AfterFuncZeroDelivery/LLGo 38216 ns/op -1101 ns/op / -2.8% (better)
Linux CreateStop/Go 292.400 ns/op +0.7 ns/op / +0.2% (worse)
Linux CreateStop/LLGo 1460 ns/op +5 ns/op / +0.3% (worse)
Linux RearmStopped/Go 116 ns/op -0.1 ns/op / -0.1% (better)
Linux RearmStopped/LLGo 831 ns/op -201 ns/op / -19.5% (better)
Linux ResetActive/Go 68.760 ns/op +0.12 ns/op / +0.2% (worse)
Linux ResetActive/LLGo 912.300 ns/op +217.4 ns/op / +31.3% (worse)
Linux ResetHeap1024/Go 67.220 ns/op -0.15 ns/op / -0.2% (better)
Linux ResetHeap1024/LLGo 134.300 ns/op -0.6 ns/op / -0.4% (better)
macOS AfterFuncZeroDelivery/Go 595.800 ns/op +51.3 ns/op / +9.4% (worse)
macOS AfterFuncZeroDelivery/LLGo 55955 ns/op +18321 ns/op / +48.7% (worse)
macOS CreateStop/Go 138 ns/op -3.6 ns/op / -2.5% (better)
macOS CreateStop/LLGo 715.900 ns/op +192.4 ns/op / +36.8% (worse)
macOS RearmStopped/Go 60.900 ns/op +2.72 ns/op / +4.7% (worse)
macOS RearmStopped/LLGo 242.900 ns/op +22.4 ns/op / +10.2% (worse)
macOS ResetActive/Go 43.580 ns/op +0.2 ns/op / +0.5% (worse)
macOS ResetActive/LLGo 136.400 ns/op +9.7 ns/op / +7.7% (worse)
macOS ResetHeap1024/Go 53.200 ns/op +10.22 ns/op / +23.8% (worse)
macOS ResetHeap1024/LLGo 71.180 ns/op +5.49 ns/op / +8.4% (worse)
Windows MinGW AfterFuncZeroDelivery/Go 568 ns/op +13.1 ns/op / +2.4% (worse)
Windows MinGW AfterFuncZeroDelivery/LLGo 188658 ns/op -311 ns/op / -0.2% (better)
Windows MinGW CreateStop/Go 120.600 ns/op +4.2 ns/op / +3.6% (worse)
Windows MinGW CreateStop/LLGo 728.400 ns/op +39 ns/op / +5.7% (worse)
Windows MinGW RearmStopped/Go 31.410 ns/op -0.05 ns/op / -0.2% (better)
Windows MinGW RearmStopped/LLGo 349.100 ns/op +69.2 ns/op / +24.7% (worse)
Windows MinGW ResetActive/Go 20.140 ns/op +0.07 ns/op / +0.3% (worse)
Windows MinGW ResetActive/LLGo 202.200 ns/op +20.4 ns/op / +11.2% (worse)
Windows MinGW ResetHeap1024/Go 20.410 ns/op -0.15 ns/op / -0.7% (better)
Windows MinGW ResetHeap1024/LLGo 102.500 ns/op -0.2 ns/op / -0.2% (better)
Windows MinGW 386 AfterFuncZeroDelivery/Go 955.800 ns/op +1.5 ns/op / +0.2% (worse)
Windows MinGW 386 AfterFuncZeroDelivery/LLGo 205092 ns/op +1050 ns/op / +0.5% (worse)
Windows MinGW 386 CreateStop/Go 194.500 ns/op +3 ns/op / +1.6% (worse)
Windows MinGW 386 CreateStop/LLGo 430.400 ns/op -90.4 ns/op / -17.4% (better)
Windows MinGW 386 RearmStopped/Go 64.360 ns/op +0.85 ns/op / +1.3% (worse)
Windows MinGW 386 RearmStopped/LLGo 312.600 ns/op -6 ns/op / -1.9% (better)
Windows MinGW 386 ResetActive/Go 39.180 ns/op -0.02 ns/op / -0.1% (better)
Windows MinGW 386 ResetActive/LLGo 1035 ns/op +30 ns/op / +3.0% (worse)
Windows MinGW 386 ResetHeap1024/Go 39.800 ns/op +0.33 ns/op / +0.8% (worse)
Windows MinGW 386 ResetHeap1024/LLGo 149.300 ns/op +1.1 ns/op / +0.7% (worse)
Windows MinGW ARM64 AfterFuncZeroDelivery/Go 660.100 ns/op -14.2 ns/op / -2.1% (better)
Windows MinGW ARM64 AfterFuncZeroDelivery/LLGo 143334 ns/op -565 ns/op / -0.4% (better)
Windows MinGW ARM64 CreateStop/Go 200.900 ns/op +7.5 ns/op / +3.9% (worse)
Windows MinGW ARM64 CreateStop/LLGo 506.600 ns/op +46.2 ns/op / +10.0% (worse)
Windows MinGW ARM64 RearmStopped/Go 70.610 ns/op +0.04 ns/op / +0.1% (worse)
Windows MinGW ARM64 RearmStopped/LLGo 172.100 ns/op -3.7 ns/op / -2.1% (better)
Windows MinGW ARM64 ResetActive/Go 30.930 ns/op 0 ns/op / +0.0%
Windows MinGW ARM64 ResetActive/LLGo 125.500 ns/op +21.5 ns/op / +20.7% (worse)
Windows MinGW ARM64 ResetHeap1024/Go 30.950 ns/op -0.14 ns/op / -0.5% (better)
Windows MinGW ARM64 ResetHeap1024/LLGo 91.440 ns/op -0.57 ns/op / -0.6% (better)
Windows MSVC AfterFuncZeroDelivery/Go 550.800 ns/op -0.2 ns/op / -0.0363% (better)
Windows MSVC AfterFuncZeroDelivery/LLGo 182393 ns/op -3187 ns/op / -1.7% (better)
Windows MSVC CreateStop/Go 114.200 ns/op -1.7 ns/op / -1.5% (better)
Windows MSVC CreateStop/LLGo 492.200 ns/op +6.7 ns/op / +1.4% (worse)
Windows MSVC RearmStopped/Go 31.250 ns/op -0.3 ns/op / -1.0% (better)
Windows MSVC RearmStopped/LLGo 312.400 ns/op +34.4 ns/op / +12.4% (worse)
Windows MSVC ResetActive/Go 20.060 ns/op -0.08 ns/op / -0.4% (better)
Windows MSVC ResetActive/LLGo 221.300 ns/op +29.2 ns/op / +15.2% (worse)
Windows MSVC ResetHeap1024/Go 20.530 ns/op -0.01 ns/op / -0.04869% (better)
Windows MSVC ResetHeap1024/LLGo 101.900 ns/op -3.2 ns/op / -3.0% (better)
Windows MSVC 386 AfterFuncZeroDelivery/Go 962.500 ns/op +0.7 ns/op / +0.1% (worse)
Windows MSVC 386 AfterFuncZeroDelivery/LLGo 203549 ns/op +1067 ns/op / +0.5% (worse)
Windows MSVC 386 CreateStop/Go 192.900 ns/op -0.2 ns/op / -0.1% (better)
Windows MSVC 386 CreateStop/LLGo 441.900 ns/op -30.9 ns/op / -6.5% (better)
Windows MSVC 386 RearmStopped/Go 64.290 ns/op +1.14 ns/op / +1.8% (worse)
Windows MSVC 386 RearmStopped/LLGo 427.600 ns/op +63.1 ns/op / +17.3% (worse)
Windows MSVC 386 ResetActive/Go 39.070 ns/op +0.19 ns/op / +0.5% (worse)
Windows MSVC 386 ResetActive/LLGo 975.200 ns/op +7.3 ns/op / +0.8% (worse)
Windows MSVC 386 ResetHeap1024/Go 39.660 ns/op +0.35 ns/op / +0.9% (worse)
Windows MSVC 386 ResetHeap1024/LLGo 141.300 ns/op -2.4 ns/op / -1.7% (better)
Windows MSVC ARM64 AfterFuncZeroDelivery/Go 663.600 ns/op -4.9 ns/op / -0.7% (better)
Windows MSVC ARM64 AfterFuncZeroDelivery/LLGo 146071 ns/op -2719 ns/op / -1.8% (better)
Windows MSVC ARM64 CreateStop/Go 199.500 ns/op -13.4 ns/op / -6.3% (better)
Windows MSVC ARM64 CreateStop/LLGo 279.500 ns/op +6.5 ns/op / +2.4% (worse)
Windows MSVC ARM64 RearmStopped/Go 70.610 ns/op +0.04 ns/op / +0.1% (worse)
Windows MSVC ARM64 RearmStopped/LLGo 167.700 ns/op +1.8 ns/op / +1.1% (worse)
Windows MSVC ARM64 ResetActive/Go 30.980 ns/op -0.08 ns/op / -0.3% (better)
Windows MSVC ARM64 ResetActive/LLGo 83.520 ns/op -3.81 ns/op / -4.4% (better)
Windows MSVC ARM64 ResetHeap1024/Go 31.190 ns/op +0.17 ns/op / +0.5% (worse)
Windows MSVC ARM64 ResetHeap1024/LLGo 93.610 ns/op +0.32 ns/op / +0.3% (worse)

Compared with 96331c1f14f3 measured in the same runner job.

@github-actions

Copy link
Copy Markdown

LLGo WebAssembly build benchmarks

87f8a2fb4d8d | workflow run | long-term charts

WebAssembly output sizes
Example, profile and compiler Wasm module vs base Generated JS glue vs base
cprintf/j32-emscripten/LLGo 155791 B -110 B / -0.1% (better) 88932 B 0 B / +0.0%
cprintf/j32-goos-js/LLGo 154776 B -212 B / -0.1% (better) 72985 B 0 B / +0.0%
cprintf/j64-emscripten-memory64/LLGo 142462 B -85 B / -0.1% (better) 92103 B 0 B / +0.0%
cprintf/w32-goos-wasip1/LLGo 15937 B 0 B / +0.0% 0 B 0 B / 0.0%
cprintf/w32-wasi/LLGo 15937 B 0 B / +0.0% 0 B 0 B / 0.0%
fmtprintf/j32-emscripten/LLGo 1634172 B +114 B / +0.006976% (worse) 119298 B 0 B / +0.0%
fmtprintf/j32-goos-js/Go 2526852 B 0 B / +0.0% 0 B 0 B / 0.0%
fmtprintf/j32-goos-js/LLGo 1699183 B +27 B / +0.001589% (worse) 89510 B 0 B / +0.0%
fmtprintf/j64-emscripten-memory64/LLGo 1515059 B +60 B / +0.00396% (worse) 122540 B 0 B / +0.0%
fmtprintf/w32-goos-wasip1/Go 2500019 B 0 B / +0.0% 0 B 0 B / 0.0%
fmtprintf/w32-goos-wasip1/LLGo 1075795 B +324 B / +0.03013% (worse) 0 B 0 B / 0.0%
fmtprintf/w32-wasi/LLGo 1077087 B +326 B / +0.03028% (worse) 0 B 0 B / 0.0%
j32-emscripten/LLGo 154987 B -104 B / -0.1% (better) 88932 B 0 B / +0.0%
j32-goos-js/Go 1895533 B 0 B / +0.0% 0 B 0 B / 0.0%
j32-goos-js/LLGo 154178 B -206 B / -0.1% (better) 72985 B 0 B / +0.0%
j64-emscripten-memory64/LLGo 141659 B -89 B / -0.1% (better) 92103 B 0 B / +0.0%
reflectcall/j32-emscripten/LLGo 1372722 B +80 B / +0.005828% (worse) 95650 B 0 B / +0.0%
reflectcall/j32-goos-js/Go 2191221 B 0 B / +0.0% 0 B 0 B / 0.0%
reflectcall/j32-goos-js/LLGo 1385566 B +95 B / +0.006857% (worse) 79699 B 0 B / +0.0%
reflectcall/j64-emscripten-memory64/LLGo 1256949 B +38 B / +0.003023% (worse) 99450 B 0 B / +0.0%
reflectcall/w32-goos-wasip1/Go 2205707 B 0 B / +0.0% 0 B 0 B / 0.0%
reflectcall/w32-goos-wasip1/LLGo 1042521 B +328 B / +0.03147% (worse) 0 B 0 B / 0.0%
reflectcall/w32-wasi/LLGo 1043682 B +333 B / +0.03192% (worse) 0 B 0 B / 0.0%
w32-goos-wasip1/Go 1909947 B 0 B / +0.0% 0 B 0 B / 0.0%
w32-goos-wasip1/LLGo 18855 B 0 B / +0.0% 0 B 0 B / 0.0%
w32-wasi/LLGo 18855 B 0 B / +0.0% 0 B 0 B / 0.0%
LLGo WebAssembly build measurements
Example and profile Build vs base
j32-emscripten 8.351 s -231.8 ms / -2.7% (better)
j32-goos-js 8.182 s -369.3 ms / -4.3% (better)
j64-emscripten-memory64 7.385 s -145 ms / -1.9% (better)
reflectcall/w32-wasi 27.718 s -16.27 ms / -0.1% (better)
w32-goos-wasip1 3.953 s -278.3 ms / -6.6% (better)
w32-wasi 3.693 s -86.81 ms / -2.3% (better)

Compared with 96331c1f14f3 measured in the same runner job.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

performance: integrated 717fbe442 regresses wasmvm GC struct allocation interpreter

1 participant